+2001-06-05 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktoolbar.c (gtk_toolbar_remove_space): new function
+
2001-06-05 Havoc Pennington <hp@redhat.com>
* gtk/gtkspinbutton.c (gtk_spin_button_set_range): clamp the value
+2001-06-05 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktoolbar.c (gtk_toolbar_remove_space): new function
+
2001-06-05 Havoc Pennington <hp@redhat.com>
* gtk/gtkspinbutton.c (gtk_spin_button_set_range): clamp the value
+2001-06-05 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktoolbar.c (gtk_toolbar_remove_space): new function
+
2001-06-05 Havoc Pennington <hp@redhat.com>
* gtk/gtkspinbutton.c (gtk_spin_button_set_range): clamp the value
+2001-06-05 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktoolbar.c (gtk_toolbar_remove_space): new function
+
2001-06-05 Havoc Pennington <hp@redhat.com>
* gtk/gtkspinbutton.c (gtk_spin_button_set_range): clamp the value
+2001-06-05 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktoolbar.c (gtk_toolbar_remove_space): new function
+
2001-06-05 Havoc Pennington <hp@redhat.com>
* gtk/gtkspinbutton.c (gtk_spin_button_set_range): clamp the value
+2001-06-05 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktoolbar.c (gtk_toolbar_remove_space): new function
+
2001-06-05 Havoc Pennington <hp@redhat.com>
* gtk/gtkspinbutton.c (gtk_spin_button_set_range): clamp the value
+2001-06-05 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktoolbar.c (gtk_toolbar_remove_space): new function
+
2001-06-05 Havoc Pennington <hp@redhat.com>
* gtk/gtkspinbutton.c (gtk_spin_button_set_range): clamp the value
position);
}
+void
+gtk_toolbar_remove_space (GtkToolbar *toolbar,
+ gint position)
+{
+ GList *children;
+ GtkToolbarChild *child;
+ gint i;
+
+ g_return_if_fail (GTK_IS_TOOLBAR (toolbar));
+
+ i = 0;
+ for (children = toolbar->children; children; children = children->next)
+ {
+ child = children->data;
+
+ if (i == position)
+ {
+ if (child->type == GTK_TOOLBAR_CHILD_SPACE)
+ {
+ toolbar->children = g_list_remove_link (toolbar->children, children);
+ g_free (child);
+ g_list_free (children);
+ toolbar->num_children--;
+
+ gtk_widget_queue_resize (GTK_WIDGET (toolbar));
+ }
+ else
+ {
+ g_warning ("Toolbar position %d is not a space", position);
+ }
+
+ return;
+ }
+
+ ++i;
+ }
+
+ g_warning ("Toolbar position %d doesn't exist", position);
+}
+
void
gtk_toolbar_append_widget (GtkToolbar *toolbar,
GtkWidget *widget,
void gtk_toolbar_prepend_space (GtkToolbar *toolbar);
void gtk_toolbar_insert_space (GtkToolbar *toolbar,
gint position);
+void gtk_toolbar_remove_space (GtkToolbar *toolbar,
+ gint position);
/* Any element type */
GtkWidget* gtk_toolbar_append_element (GtkToolbar *toolbar,